import instance from "../utils/request"
//轮播图模块
/**
 * 获取轮播图列表
 * @params params 
 * @returns 
 */
export const getswipeListAPI = (params: any) => instance.get("/api/v1/admin/banner", {params})
/**
 * 删除当前选中的数据
 * @returns 
 */
export const delswipeAPI = (id: string) => instance.delete("/api/v1/admin/banner/" + id);
/**
 * 根据id获取一条数据
 * @param id 
 * @returns 
 */
export const getByIdAPI = (id: string) => instance.get("/api/v1/admin/banner/" + id);
/**
 * 修改当前数据
 * @param id 
 * @returns 
 */
export const putByIdAPI = (id: string,data:any) => instance.put("/api/v1/admin/banner/" + id,data);
/**
 * 新增数据
 * @param data 
 * @returns 
 */
export const addAPI = (data: any) => instance.post("/api/v1/admin/banner", data);